{% extends 'TopxiaWebBundle::bootstrap-modal-layout.html.twig' %}

{% set modal_class= "modal-lg" %}

{% block title %}选择课程{% endblock %}
{% block body %}
<style>
.course-item:hover {
    cursor: pointer;
}
.course-wide-list .course-item .select{

}
</style>

{#{% include 'TopxiaWebBundle:OpenCourseManage:pick-tab.html.twig' %}#}

<form class="form-inline form-search" role="search-form" action="{{ path('open_course_course_search',{id:courseId,filter:filter}) }}">
  <div class="form-group ">
    <input type="text" class="form-control" name="key" id="enterSearch" value="" placeholder="按课程标题或关键字">
  </div>
  <button type="button" class="btn btn-primary"  id="search" >搜索</button>
  <a class="btn btn-primary" id="all-courses" data-url="{{path('open_course_manage_course_pick',{id:courseId,filter:filter})}}">清除搜索</a>
</form>

<div class="row mtl">
  <div class="col-md-12">
    <div class="courses-list">
      {% include('TopxiaWebBundle:Course:course-select-list.html.twig') %}
      {{ web_macro.paginator(paginator) }}
    </div>
  </div>
</div>

{% endblock %}

{% block footer %}
  <button id="sure" class="btn btn-primary pull-right" data-url="{{path('open_course_recommended_course_select', {id:courseId})}}">添加</button>
  <button type="button" class="btn btn-link pull-right" data-dismiss="modal">取消</button>

  <script>app.load('topxiawebbundle/controller/open-course-manage/pick')</script>
{% endblock %}